from django.urls import path

from apps.areas.views import AreasView,SubAreasView,AddressView,DefaultAddressView,UpdateDestroyAddressView,UpdateTitleAddressView,ChangePasswordView

urlpatterns = {
# 获取所有省
path('areas/',AreasView.as_view()),
#获取市和县
path('areas/<area_id>/',SubAreasView.as_view()),
#存地址
path('addresses/create/',AddressView.as_view()),
#获取地址
path('addresses/',AddressView.as_view()),
#设置默认地址
path('addresses/<address_id>/default/',DefaultAddressView.as_view()),
#删除和修改地址
path('addresses/<address_id>/',UpdateDestroyAddressView.as_view()),
#修改标题
path('addresses/<address_id>/title/',UpdateTitleAddressView.as_view()),
#修改密码
path('password/',ChangePasswordView.as_view()),
}